package com.jsh.service;

import com.jsh.dao.AttachmentMapper;
import com.jsh.pojo.Attachment;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@Service
public class AttachmentServiceImpl implements AttachmentService{
    @Autowired
   private AttachmentMapper attachmentMapper;
    @Override
    public int deleteByPrimaryKey(Integer emailId) {
        return attachmentMapper.deleteByPrimaryKey(emailId);
    }

    @Override
    public int insert(Attachment record) {
        return attachmentMapper.insert(record);
    }

    @Override
    public Attachment selectByPrimaryKey(Integer emailId) {
        return attachmentMapper.selectByPrimaryKey(emailId);
    }

    @Override
    public List<Attachment> selectAll() {
        return attachmentMapper.selectAll();
    }

    @Override
    public int updateByPrimaryKey(Attachment record) {
        return attachmentMapper.updateByPrimaryKey(record);
    }
}
